
import java.util.*;

class SplitTest {

    public static void main(String[] args) {

        String dataLine = "<end>";
        if (dataLine.matches("<[^>]*>")) {
            if (!dataLine.matches("<end>")) {
                String[] tokens = dataLine.split("<");
                String[] tokens2 = tokens[1].split(">");
                System.out.println("-" + tokens2[0]);
            } else{
                System.out.println("abc");
            }
        }

    }
}